import { createApp } from 'vue'
import './assets/sass/base.scss'
import App from './App.vue'
import router from './router'
import './assets/icon/iconfont.css'

import Request from '@/http/Request'
import Message from '@/utils/Message'
import Confirm from '@/utils/Confirm'
// 二次封装表格，抽离出封面cover
import Table from '@/components/Table.vue'
import Cover from '@/components/Cover.vue'
import CoverUpload from '@/components/CoverUpload.vue'

const app = createApp(App)

app.use(router)
app.config.globalProperties.Request = Request
app.config.globalProperties.Message = Message
app.config.globalProperties.Confirm = Confirm
app.config.globalProperties.globalInfo = {
  imageUrl: "/api/file/getImage/"
}
// 二次封装的table挂载全局
app.component('Table', Table)
app.component('Cover', Cover)
app.component('CoverUpload', CoverUpload)
app.mount('#app')
